using System;
using System.Collections.Generic;
using System.Text;
using Colman.Rpg.Messaging;

namespace Colman.Rpg.Server.Workflow
{
    /// <summary>
    /// WorkflowHandler delegate
    /// </summary>
    /// <param name="e"> Workflow Handler Args </param>
    public delegate void WorkflowHandler(WorkflowHandlerArgs e);

    /// <summary>
    /// Used by the <see cref="WorkflowHandler"/> delegate.
    /// </summary>
    public class WorkflowHandlerArgs
    {
        /// <summary>
        /// Creates a new instance of <see cref="WorkflowHandlerArgs" />.
        /// </summary>
        /// <param name="request">Represents the request message.</param>
        [System.Diagnostics.DebuggerStepThrough]
        public WorkflowHandlerArgs(RequestMessage request)
        {
            this.request = request;
        }

        #region RequestMessage Request { get; } (request)
        private RequestMessage request;

        /// <summary>
        /// Gets the request message.
        /// </summary>
        [System.ComponentModel.Description("Indicates the request message.")]
        public RequestMessage Request
        {
            [System.Diagnostics.DebuggerStepThrough]
            get
            {
                return this.request;
            }
        }
        #endregion

        #region List<ResponseMessage> Responses { get; } (responses)
        private List<ResponseMessage> responses = new List<ResponseMessage>();

        /// <summary>
        /// Gets the list of responses to be sent.
        /// </summary>
        [System.ComponentModel.Description("Indicates the list of responses to be sent.")]
        public List<ResponseMessage> Responses
        {
            [System.Diagnostics.DebuggerStepThrough]
            get
            {
                return this.responses;
            }
        }
        #endregion
    }
}
